#include <iostream>
#include <vector>
using namespace std;
class Solution {
public:
    int peakIndexInMountainArray(vector<int>& arr) {
        int left = 0;
        int right = arr.size() - 1;
        int mid = left + (right - left + 1) / 2;
        while (left < right)
        {
            if (arr[mid] < arr[mid - 1])
            {
                right = mid - 1;
                mid = left + (right - left + 1) / 2;
            }
            else
            {
                left = mid;
                mid = left + (right - left + 1) / 2;
            }
        }
        return left;
    }
};
int main()
{
	return 0;
}